const webpack = require("webpack");
module.exports = {
    publicPath: './',
    assetsDir: 'static',
    productionSourceMap: false,
    devServer: {
        port: 3331,     // 端口号
    },
    devServer: {
        proxy: {
            '/api':{
                target:'http://41d269ed.cpolar.io/',
                changeOrigin:true,
                pathRewrite:{
                    '/api':''
                }
            },
        },
        disableHostCheck: true
    },

    configureWebpack: {
        // 百度高德地图配置
        externals: {
            'BMap': 'BMap',
            'AMap': 'AMap',
            'BMap_Symbol_SHAPE_POINT': 'BMap_Symbol_SHAPE_POINT'
          },
        plugins: [
          new webpack.ProvidePlugin({
            $: "jquery",
            jQuery: "jquery",
            "window.jQuery": "jquery",
            Popper: ["popper.js", "default"]
          })
        ]
      }
}
